package com.ruoyi.mes.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.mes.mapper.ProCraftProcessMapper;
import com.ruoyi.mes.domain.ProCraftProcess;
import com.ruoyi.mes.service.IProCraftProcessService;

/**
 * 工艺工序Service业务层处理
 * 
 * @author ruoyi
 * @date 2024-05-30
 */
@Service
public class ProCraftProcessServiceImpl implements IProCraftProcessService 
{
    @Autowired
    private ProCraftProcessMapper proCraftProcessMapper;

    /**
     * 查询工艺工序
     * 
     * @param id 工艺工序主键
     * @return 工艺工序
     */
    @Override
    public ProCraftProcess selectProCraftProcessById(Long id)
    {
        return proCraftProcessMapper.selectProCraftProcessById(id);
    }

    /**
     * 查询工艺工序列表
     * 
     * @param proCraftProcess 工艺工序
     * @return 工艺工序
     */
    @Override
    public List<ProCraftProcess> selectProCraftProcessList(ProCraftProcess proCraftProcess)
    {
        return proCraftProcessMapper.selectProCraftProcessList(proCraftProcess);
    }

    /**
     * 新增工艺工序
     * 
     * @param proCraftProcess 工艺工序
     * @return 结果
     */
    @Override
    public int insertProCraftProcess(ProCraftProcess proCraftProcess)
    {
        return proCraftProcessMapper.insertProCraftProcess(proCraftProcess);
    }

    /**
     * 修改工艺工序
     * 
     * @param proCraftProcess 工艺工序
     * @return 结果
     */
    @Override
    public int updateProCraftProcess(ProCraftProcess proCraftProcess)
    {
        return proCraftProcessMapper.updateProCraftProcess(proCraftProcess);
    }

    /**
     * 批量删除工艺工序
     * 
     * @param ids 需要删除的工艺工序主键
     * @return 结果
     */
    @Override
    public int deleteProCraftProcessByIds(Long[] ids)
    {
        return proCraftProcessMapper.deleteProCraftProcessByIds(ids);
    }

    /**
     * 删除工艺工序信息
     * 
     * @param id 工艺工序主键
     * @return 结果
     */
    @Override
    public int deleteProCraftProcessById(Long id)
    {
        return proCraftProcessMapper.deleteProCraftProcessById(id);
    }
}
